package com.ts.api.module.api.convert.receive.context;

import com.ts.api.module.api.convert.receive.convert.ApiReceivePullNoticeConvert;
import com.ts.api.module.api.convert.receive.convert.ApiReceivePushNoticeConvert;
import com.ts.api.module.api.convert.receive.handler.ApiReceiveNoticeHandler;
import org.springframework.beans.factory.annotation.Autowired;
import org.springframework.stereotype.Component;

/**
 *  API通知类转换器上下文
 *
 *  @author Pan
 */
@Component
public class ApiReceiveNoticeConvertContext {

    @Autowired
    private ApiReceivePushNoticeConvert apiReceivePushNoticeConvert;
    @Autowired
    private ApiReceivePullNoticeConvert apiReceivePullNoticeConvert;

    /**
     *  渠道通知类-获取默认进件拉取通知上下文
     *
     *  @author Pan
     *  @return ApiHttpNoticeHandler
     */
    public ApiReceiveNoticeHandler getDefaultPullApplyNotice() {
        return apiReceivePushNoticeConvert.getDefaultHandler();
    }

    /**
     *  渠道通知类-获取默认进件推送通知上下文
     *
     *  @author Pan
     *  @return ApiHttpNoticeHandler
     */
    public ApiReceiveNoticeHandler getDefaultPushApplyNotice() {
        return apiReceivePullNoticeConvert.getDefaultHandler();
    }
}
